jQuery mobile List-View is not working after adding some jquery code [closed]
Posted
by
Kaidul Islam Sazal
on Pro Webmasters
See other posts from Pro Webmasters
or by Kaidul Islam Sazal
Published on 2012-11-23T00:08:06Z
Indexed on
2012/11/23
5:10 UTC
Read the original article
Hit count: 340
jQuery
I am using jquery mobile and I have an array makeArray
in jquery and I have created few listview by the values of the array.Everything works fine.But the jquery mobile list-view style is not shown. Rather it is shown an ordinary list view. This is my code:
$(document).ready(function(){
var url = "inventory/inventory.json";
var makeArray = new Array();
$.getJSON(url, function(data){
$.each(data, function(index, item){
if(($.inArray(item.make, makeArray)) == -1){
makeArray.push(item.make);
$('.upper_case')
.append('<li data-icon="list-arrow"> <a href="trade_form.php?='+ item.make +'"><img src="images/car_logo/buick.png" class="ui-li-thumb"/>' + item.make + '</a></li>');
}
});
});
});
© Pro Webmasters or respective owner